<%--
  Created by IntelliJ IDEA.
  User: 86130
  Date: 2025/3/27
  Time: 08:32
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>工作台 - OA办公系统</title>
  <link href="${pageContext.request.contextPath}/css/tailwind.min.css" rel="stylesheet">
  <link rel="stylesheet" href="${pageContext.request.contextPath}/css/all.min.css">
  <link rel="stylesheet" href="${pageContext.request.contextPath}/css/style.css">
</head>
<body class="bg-gray-50 h-screen overflow-auto p-6">
<div class="container mx-auto fade-in">
  <!-- 欢迎信息 -->
  <div class="flex justify-between items-center mb-6">
    <div>
      <h1 class="text-2xl font-bold text-gray-800">您好，${user.username}</h1>
      <p class="text-gray-600">今天是 <span id="currentDate"></span>，祝您工作愉快！</p>
    </div>
    <div class="text-right">
      <p class="text-sm text-gray-500">上次登录: 2023-06-15 08:30:45</p>
      <p class="text-sm text-gray-500"><%=request.getLocalAddr()%>></p>
    </div>
  </div>
</div>

<script>
  // 显示当前日期
  document.addEventListener('DOMContentLoaded', function() {
    const now = new Date();
    const options = { year: 'numeric', month: 'long', day: 'numeric', weekday: 'long' };
    document.getElementById('currentDate').textContent = now.toLocaleDateString('zh-CN', options);
  });
</script>
</body>
</html>